import 'package:dio/dio.dart';
import 'package:gpt_request_lib/data/chat_message.dart';
import 'package:gpt_request_lib/postdata/gpt_message_post.dart';
import 'package:gpt_request_lib/reques_api.dart';
import 'package:retrofit/retrofit.dart';

part 'gpt_repository.g.dart';
@RestApi(baseUrl: ChatGptApi.baseUrl)
abstract class GPTRepository {

  factory GPTRepository(Dio dio, {String? baseUrl}) = _GPTRepository;

  @POST(ChatGptApi.chat)
  Future<ChatCompletion> gptChatMessage(@Body() GptMessagePost gptMessagePost);
}